package com.briup.gsauestore.dao;

import com.briup.gsauestore.bean.Category;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * @author adam
 * @date 2022/1/12
 */
@Repository
public interface ICategoryDao  extends JpaRepository<Category,Long> {

    List<Category> findByParentIdIsNull();

    List<Category> findByParentId(long parentId);
}
